<template>
    <div class="index-lists">
        <!-- <el-card class="!border-none" shadow="never">
            <el-form ref="formRef" class="mb-[-16px]" :model="queryParams" :inline="true">
                <el-form-item label="案件名称" prop="caseName">
                    <el-input class="w-[280px]" v-model="queryParams.caseName" />
                </el-form-item>
                <el-form-item label="案件类型" prop="caseType">
                    <el-select v-model="queryParams.caseType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="业务类型" prop="businessType">
                    <el-select v-model="queryParams.businessType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="申请类型" prop="putinType">
                    <el-select v-model="queryParams.putinType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="承办部门" prop="undertakingDepartment">
                    <el-select v-model="queryParams.undertakingDepartment" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="处理人" prop="conductor">
                    <el-input class="w-[280px]" v-model="queryParams.conductor" />
                </el-form-item>
                <el-form-item label="税率" prop="taxRate">
                    <el-input class="w-[280px]" v-model="queryParams.taxRate" />
                </el-form-item>
                <el-form-item label="成本类型" prop="costType">
                    <el-select v-model="queryParams.costType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="成本" prop="cost">
                    <el-input class="w-[280px]" v-model="queryParams.cost" />
                </el-form-item>
                <el-form-item label="贡献额" prop="contributionPool">
                    <el-input class="w-[280px]" v-model="queryParams.contributionPool" />
                </el-form-item>
                <el-form-item label="所属分布" prop="ownershipDistribution">
                    <el-select v-model="queryParams.ownershipDistribution" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="选择已有案件" prop="haveCase">
                    <el-input class="w-[280px]" v-model="queryParams.haveCase" />
                </el-form-item>
                <el-form-item label="申请国家（地区）" prop="designatedCountry">
                    <el-input class="w-[280px]" v-model="queryParams.designatedCountry" />
                </el-form-item>
                <el-form-item label="商标类别" prop="brandType">
                    <el-select v-model="queryParams.brandType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="类别数量" prop="classQuantity">
                    <el-input class="w-[280px]" v-model="queryParams.classQuantity" />
                </el-form-item>
                <el-form-item label="申请数量" prop="quantity">
                    <el-input class="w-[280px]" v-model="queryParams.quantity" />
                </el-form-item>
                <el-form-item label="官费" prop="officialFee">
                    <el-input class="w-[280px]" v-model="queryParams.officialFee" />
                </el-form-item>
                <el-form-item label="代理费" prop="agencyFee">
                    <el-input class="w-[280px]" v-model="queryParams.agencyFee" />
                </el-form-item>
                <el-form-item label="第三方费" prop="hirdPartyPayment">
                    <el-input class="w-[280px]" v-model="queryParams.hirdPartyPayment" />
                </el-form-item>
                <el-form-item label="签单金额" prop="signedAmount">
                    <el-input class="w-[280px]" v-model="queryParams.signedAmount" />
                </el-form-item>
                <el-form-item label="开票金额" prop="invoiceValue">
                    <el-input class="w-[280px]" v-model="queryParams.invoiceValue" />
                </el-form-item>
                <el-form-item label="实收金额" prop="fundsReceived">
                    <el-input class="w-[280px]" v-model="queryParams.fundsReceived" />
                </el-form-item>
                <el-form-item label="实收日期" prop="paidupDate">
                    <daterange-picker v-model:startTime="queryParams.paidupDateStart"
                        v-model:endTime="queryParams.paidupDateEnd" />
                </el-form-item>
                <el-form-item label="我方案号" prop="planNumber">
                    <el-input class="w-[280px]" v-model="queryParams.planNumber" />
                </el-form-item>
                <el-form-item label="案件状态" prop="caseStatus">
                    <el-select v-model="queryParams.caseStatus" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="当前案件环节" prop="caseLink">
                    <el-input class="w-[280px]" v-model="queryParams.caseLink" />
                </el-form-item>
                <el-form-item label="备注" prop="remark">
                    <el-input class="w-[280px]" v-model="queryParams.remark" />
                </el-form-item>
                <el-form-item label="案件类型id" prop="caseNameid">
                    <el-input class="w-[280px]" v-model="queryParams.caseNameid" />
                </el-form-item>
                <el-form-item label="业务类型id" prop="businessTypeid">
                    <el-input class="w-[280px]" v-model="queryParams.businessTypeid" />
                </el-form-item>
                <el-form-item label="承办部门id" prop="undertakingDepartmentid">
                    <el-input class="w-[280px]" v-model="queryParams.undertakingDepartmentid" />
                </el-form-item>
                <el-form-item label="所属分部id" prop="ownershipDistributionid">
                    <el-input class="w-[280px]" v-model="queryParams.ownershipDistributionid" />
                </el-form-item>
                <el-form-item label="成本类型id" prop="costTypeid">
                    <el-input class="w-[280px]" v-model="queryParams.costTypeid" />
                </el-form-item>
                <el-form-item label="相关类型id" prop="correlationTypeid">
                    <el-input class="w-[280px]" v-model="queryParams.correlationTypeid" />
                </el-form-item>
                <el-form-item label="是否立案" prop="isRegister">
                    <el-select v-model="queryParams.isRegister" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="是否作废" prop="isInvalid">
                    <el-select v-model="queryParams.isInvalid" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="是否已有案件" prop="isExistingcase">
                    <el-select v-model="queryParams.isExistingcase" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="是否需要纸质通知书" prop="isPapernotice">
                    <el-select v-model="queryParams.isPapernotice" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="客户文号" prop="customerDocumentNumber">
                    <el-input class="w-[280px]" v-model="queryParams.customerDocumentNumber" />
                </el-form-item>
                <el-form-item label="版权类型" prop="copyrightType">
                    <el-select v-model="queryParams.copyrightType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="案件流向" prop="caseFlow">
                    <el-select v-model="queryParams.caseFlow" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="案源国" prop="countryOfOrigin">
                    <el-input class="w-[280px]" v-model="queryParams.countryOfOrigin" />
                </el-form-item>
                <el-form-item label="代理机构" prop="agency">
                    <el-input class="w-[280px]" v-model="queryParams.agency" />
                </el-form-item>
                <el-form-item label="申请方式" prop="proposalForm">
                    <el-input class="w-[280px]" v-model="queryParams.proposalForm" />
                </el-form-item>
                <el-form-item label="有无材料" prop="isMaterials">
                    <el-select v-model="queryParams.isMaterials" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="是否代办资助" prop="isFund">
                    <el-select v-model="queryParams.isFund" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="起始阶段" prop="initialPeriod">
                    <el-select v-model="queryParams.initialPeriod" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="受理号" prop="referenceNumber">
                    <el-input class="w-[280px]" v-model="queryParams.referenceNumber" />
                </el-form-item>
                <el-form-item label="合同编号" prop="contractNumber">
                    <el-input class="w-[280px]" v-model="queryParams.contractNumber" />
                </el-form-item>
                <el-form-item label="预算" prop="budget">
                    <el-input class="w-[280px]" v-model="queryParams.budget" />
                </el-form-item>
                <el-form-item label="作者" prop="author">
                    <el-input class="w-[280px]" v-model="queryParams.author" />
                </el-form-item>
                <el-form-item label="归属地" prop="homeLocation">
                    <el-input class="w-[280px]" v-model="queryParams.homeLocation" />
                </el-form-item>
                <el-form-item label="软件简称" prop="softwareAbbreviation">
                    <el-input class="w-[280px]" v-model="queryParams.softwareAbbreviation" />
                </el-form-item>
                <el-form-item label="版本号" prop="versionNumber">
                    <el-input class="w-[280px]" v-model="queryParams.versionNumber" />
                </el-form-item>
                <el-form-item label="软件作品说明" prop="softwareWorkDescription">
                    <el-input class="w-[280px]" v-model="queryParams.softwareWorkDescription" />
                </el-form-item>
                <el-form-item label="开发完成日期" prop="developmentCompletionDate">
                    <daterange-picker v-model:startTime="queryParams.developmentCompletionDateStart"
                        v-model:endTime="queryParams.developmentCompletionDateEnd" />
                </el-form-item>
                <el-form-item label="发表状态" prop="publishedStatus">
                    <el-select v-model="queryParams.publishedStatus" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="硬件环境" prop="hardwareEnvironment">
                    <el-input class="w-[280px]" v-model="queryParams.hardwareEnvironment" />
                </el-form-item>
                <el-form-item label="软件环境" prop="softwareEnvironment">
                    <el-input class="w-[280px]" v-model="queryParams.softwareEnvironment" />
                </el-form-item>
                <el-form-item label="编程语言" prop="programmingLanguage">
                    <el-input class="w-[280px]" v-model="queryParams.programmingLanguage" />
                </el-form-item>
                <el-form-item label="源程序量" prop="sourceQuantity">
                    <el-input class="w-[280px]" v-model="queryParams.sourceQuantity" />
                </el-form-item>
                <el-form-item label="主要功能和技术特点" prop="functionAndArt">
                    <el-input class="w-[280px]" v-model="queryParams.functionAndArt" />
                </el-form-item>
                <el-form-item label="处理事项" prop="handlingInformation">
                    <el-input class="w-[280px]" v-model="queryParams.handlingInformation" />
                </el-form-item>
                <el-form-item label="委托日期" prop="principalDates">
                    <daterange-picker v-model:startTime="queryParams.principalDatesStart"
                        v-model:endTime="queryParams.principalDatesEnd" />
                </el-form-item>
                <el-form-item label="客户期限" prop="customerTerm">
                    <daterange-picker v-model:startTime="queryParams.customerTermStart"
                        v-model:endTime="queryParams.customerTermEnd" />
                </el-form-item>
                <el-form-item label="内部期限" prop="internalWearLife">
                    <daterange-picker v-model:startTime="queryParams.internalWearLifeStart"
                        v-model:endTime="queryParams.internalWearLifeEnd" />
                </el-form-item>
                <el-form-item label="是否配案" prop="isStateCompensation">
                    <el-select v-model="queryParams.isStateCompensation" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="点数用户" prop="click">
                    <el-input class="w-[280px]" v-model="queryParams.click" />
                </el-form-item>
                <el-form-item label="共有人" prop="partOwner">
                    <el-input class="w-[280px]" v-model="queryParams.partOwner" />
                </el-form-item>
                <el-form-item label="办理事项" prop="todonote">
                    <el-input class="w-[280px]" v-model="queryParams.todonote" />
                </el-form-item>
                <el-form-item label="办理日期" prop="manageDate">
                    <daterange-picker v-model:startTime="queryParams.manageDateStart"
                        v-model:endTime="queryParams.manageDateEnd" />
                </el-form-item>
                <el-form-item label="点数类型" prop="countType">
                    <el-select v-model="queryParams.countType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="点数数量" prop="numberOfPoints">
                    <el-input class="w-[280px]" v-model="queryParams.numberOfPoints" />
                </el-form-item>
                <el-form-item label="点数状态" prop="addtotalstatepoint">
                    <el-input class="w-[280px]" v-model="queryParams.addtotalstatepoint" />
                </el-form-item>
                <el-form-item label="提成日期" prop="royaltyDate">
                    <daterange-picker v-model:startTime="queryParams.royaltyDateStart"
                        v-model:endTime="queryParams.royaltyDateEnd" />
                </el-form-item>
                <el-form-item label="工作量点数" prop="workPoints">
                    <el-input class="w-[280px]" v-model="queryParams.workPoints" />
                </el-form-item>
                <el-form-item label="创建人员" prop="creator">
                    <el-input class="w-[280px]" v-model="queryParams.creator" />
                </el-form-item>
                <el-form-item label="费用类型" prop="chargeType">
                    <el-select v-model="queryParams.chargeType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="币别" prop="currency">
                    <el-input class="w-[280px]" v-model="queryParams.currency" />
                </el-form-item>
                <el-form-item label="金额" prop="sum">
                    <el-input class="w-[280px]" v-model="queryParams.sum" />
                </el-form-item>
                <el-form-item label="预请款日" prop="advancePaymentDate">
                    <daterange-picker v-model:startTime="queryParams.advancePaymentDateStart"
                        v-model:endTime="queryParams.advancePaymentDateEnd" />
                </el-form-item>
                <el-form-item label="请款单号" prop="paymentRequestNumber">
                    <el-input class="w-[280px]" v-model="queryParams.paymentRequestNumber" />
                </el-form-item>
                <el-form-item label="请款日期" prop="requestedDate">
                    <daterange-picker v-model:startTime="queryParams.requestedDateStart"
                        v-model:endTime="queryParams.requestedDateEnd" />
                </el-form-item>
                <el-form-item label="应收日期" prop="accountsDate">
                    <daterange-picker v-model:startTime="queryParams.accountsDateStart"
                        v-model:endTime="queryParams.accountsDateEnd" />
                </el-form-item>
                <el-form-item label="发票号" prop="invoiceNumber">
                    <el-input class="w-[280px]" v-model="queryParams.invoiceNumber" />
                </el-form-item>
                <el-form-item label="费用名称" prop="chargeName">
                    <el-input class="w-[280px]" v-model="queryParams.chargeName" />
                </el-form-item>
                <el-form-item label="费用描述" prop="chargeDepict">
                    <el-input class="w-[280px]" v-model="queryParams.chargeDepict" />
                </el-form-item>
                <el-form-item label="费用描述英文" prop="chargeDepictfine">
                    <el-input class="w-[280px]" v-model="queryParams.chargeDepictfine" />
                </el-form-item>
                <el-form-item label="应收金额" prop="extendedAmount">
                    <el-input class="w-[280px]" v-model="queryParams.extendedAmount" />
                </el-form-item>
                <el-form-item label="折扣率" prop="discountRate">
                    <el-input class="w-[280px]" v-model="queryParams.discountRate" />
                </el-form-item>
                <el-form-item label="数量" prop="count">
                    <el-input class="w-[280px]" v-model="queryParams.count" />
                </el-form-item>
                <el-form-item label="汇率" prop="parities">
                    <el-input class="w-[280px]" v-model="queryParams.parities" />
                </el-form-item>
                <el-form-item label="收款公司账户" prop="collectingCompanyAccount">
                    <el-input class="w-[280px]" v-model="queryParams.collectingCompanyAccount" />
                </el-form-item>
                <el-form-item label="收款状态" prop="collectionStatus">
                    <el-select v-model="queryParams.collectionStatus" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="账户明细" prop="accountDetails">
                    <el-input class="w-[280px]" v-model="queryParams.accountDetails" />
                </el-form-item>
                <el-form-item label="开票时间" prop="slt">
                    <daterange-picker v-model:startTime="queryParams.sltStart" v-model:endTime="queryParams.sltEnd" />
                </el-form-item>
                <el-form-item label="外方账单号" prop="externalBillingNumber">
                    <el-input class="w-[280px]" v-model="queryParams.externalBillingNumber" />
                </el-form-item>
                <el-form-item label="外方账单日期" prop="externalBillingDate">
                    <daterange-picker v-model:startTime="queryParams.externalBillingDateStart"
                        v-model:endTime="queryParams.externalBillingDateEnd" />
                </el-form-item>
                <el-form-item label="垫交状态" prop="beddingCondition">
                    <el-input class="w-[280px]" v-model="queryParams.beddingCondition" />
                </el-form-item>
                <el-form-item label="垫交人" prop="handOver">
                    <el-input class="w-[280px]" v-model="queryParams.handOver" />
                </el-form-item>
                <el-form-item label="费用备注" prop="expenseNote">
                    <el-input class="w-[280px]" v-model="queryParams.expenseNote" />
                </el-form-item>
                <el-form-item label="费减类型" prop="reductionType">
                    <el-select v-model="queryParams.reductionType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="实际币别" prop="actualCurrency">
                    <el-input class="w-[280px]" v-model="queryParams.actualCurrency" />
                </el-form-item>
                <el-form-item label="官方期限" prop="officialDeadline">
                    <daterange-picker v-model:startTime="queryParams.officialDeadlineStart"
                        v-model:endTime="queryParams.officialDeadlineEnd" />
                </el-form-item>
                <el-form-item label="我方文号" prop="ourRef">
                    <el-input class="w-[280px]" v-model="queryParams.ourRef" />
                </el-form-item>
                <el-form-item label="相关案名称" prop="relevantCaseName">
                    <el-input class="w-[280px]" v-model="queryParams.relevantCaseName" />
                </el-form-item>
                <el-form-item label="相关类型" prop="correlationType">
                    <el-select v-model="queryParams.correlationType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="操作人ID" prop="userId">
                    <el-input class="w-[280px]" v-model="queryParams.userId" />
                </el-form-item>
                <el-form-item label="操作人名称" prop="userName">
                    <el-input class="w-[280px]" v-model="queryParams.userName" />
                </el-form-item>
                <el-form-item label="修改人编号" prop="updateUserId">
                    <el-input class="w-[280px]" v-model="queryParams.updateUserId" />
                </el-form-item>
                <el-form-item label="修改人名称" prop="updateUserName">
                    <el-input class="w-[280px]" v-model="queryParams.updateUserName" />
                </el-form-item>
                <el-form-item>
                    <el-button type="primary" @click="resetPage">查询</el-button>
                    <el-button @click="resetParams">重置</el-button>
                </el-form-item>
            </el-form>
        </el-card> -->
        <el-card class="!border-none mt-4" shadow="never">
            <div style="display: flex; align-items: center">
                <el-button v-perms="['case:add']" type="primary" @click="handleAdd()">
                    <template #icon>
                        <icon name="el-icon-Plus" />
                    </template>
                    新增案件
                </el-button>

                <el-form-item label="案件类型" prop="caseType" style="margin-top: 20px">
                    <el-select v-model="queryParams.caseType" class="w-[280px]" clearable>
                        <el-option label="家族案件" value="1" />
                        <el-option label="技术相关" value="2" />
                        <el-option label="同日申请" value="3" />
                        <el-option label="同日递交" value="4" />
                    </el-select>
                </el-form-item>
                <div style="margin-left: 20px">
                    指定开卷信息关联勾选下面家族案件勾选框可关联（开卷案件数量超过一个可关联）
                </div>
            </div>
            <el-table class="mt-4" size="large" v-loading="pager.loading" :data="pager.lists" stripe>
                <el-table-column type="selection" width="55" />
                <el-table-column label="案件名称" prop="caseName" min-width="100" />
                <!-- <el-table-column label="案件类型" prop="caseType" min-width="100" /> -->
                <el-table-column label="业务类型" prop="businessType" min-width="100" />
                <el-table-column label="申请类型" prop="putinType" min-width="100" />
                <el-table-column label="承办部门" prop="undertakingDepartment" min-width="100" />
                <el-table-column label="处理人" prop="conductor" min-width="100" />
                <el-table-column label="我方文号" prop="ourRef" min-width="100" />
                <el-table-column label="客户文号" prop="customerDocumentNumber" min-width="100" />
                <el-table-column label="合同编号" prop="contractNumber" min-width="100" />
                <el-table-column label="处理事项" prop="handlingInformation" min-width="100" />
                <el-table-column label="国家（地区）" prop="designatedCountry" min-width="100" />
                <!-- <el-table-column label="税率" prop="taxRate" min-width="100" /> -->
                <!-- <el-table-column label="成本类型" prop="costType" min-width="100" />
                <el-table-column label="成本" prop="cost" min-width="100" /> -->
                <!-- <el-table-column label="贡献额" prop="contributionPool" min-width="100" /> -->
                <!-- <el-table-column label="所属分布" prop="ownershipDistribution" min-width="100" /> -->
                <!-- <el-table-column label="选择已有案件" prop="haveCase" min-width="100" /> -->
                <!-- <el-table-column label="商标类别" prop="brandType" min-width="100" />
                <el-table-column label="类别数量" prop="classQuantity" min-width="100" />
                <el-table-column label="申请数量" prop="quantity" min-width="100" />
                <el-table-column label="官费" prop="officialFee" min-width="100" />
                <el-table-column label="代理费" prop="agencyFee" min-width="100" />
                <el-table-column label="第三方费" prop="hirdPartyPayment" min-width="100" />
                <el-table-column label="签单金额" prop="signedAmount" min-width="100" />
                <el-table-column label="开票金额" prop="invoiceValue" min-width="100" />
                <el-table-column label="实收金额" prop="fundsReceived" min-width="100" />
                <el-table-column label="实收日期" prop="paidupDate" min-width="100" />
                <el-table-column label="我方案号" prop="planNumber" min-width="100" />
                <el-table-column label="案件状态" prop="caseStatus" min-width="100" />
                <el-table-column label="当前案件环节" prop="caseLink" min-width="100" />
                <el-table-column label="备注" prop="remark" min-width="100" />

                <el-table-column label="是否立案" prop="isRegister" min-width="100" />
                <el-table-column label="是否作废" prop="isInvalid" min-width="100" />
                <el-table-column label="是否已有案件" prop="isExistingcase" min-width="100" />
                <el-table-column label="是否需要纸质通知书" prop="isPapernotice" min-width="100" />

                <el-table-column label="版权类型" prop="copyrightType" min-width="100" />
                <el-table-column label="案件流向" prop="caseFlow" min-width="100" />
                <el-table-column label="案源国" prop="countryOfOrigin" min-width="100" />
                <el-table-column label="代理机构" prop="agency" min-width="100" />
                <el-table-column label="申请方式" prop="proposalForm" min-width="100" />
                <el-table-column label="有无材料" prop="isMaterials" min-width="100" />
                <el-table-column label="是否代办资助" prop="isFund" min-width="100" />
                <el-table-column label="起始阶段" prop="initialPeriod" min-width="100" />
                <el-table-column label="受理号" prop="referenceNumber" min-width="100" />

                <el-table-column label="预算" prop="budget" min-width="100" />
                <el-table-column label="作者" prop="author" min-width="100" />
                <el-table-column label="归属地" prop="homeLocation" min-width="100" />
                <el-table-column label="软件简称" prop="softwareAbbreviation" min-width="100" />
                <el-table-column label="版本号" prop="versionNumber" min-width="100" />
                <el-table-column label="软件作品说明" prop="softwareWorkDescription" min-width="100" />
                <el-table-column label="开发完成日期" prop="developmentCompletionDate" min-width="100" />
                <el-table-column label="发表状态" prop="publishedStatus" min-width="100" />
                <el-table-column label="硬件环境" prop="hardwareEnvironment" min-width="100" />
                <el-table-column label="软件环境" prop="softwareEnvironment" min-width="100" />
                <el-table-column label="编程语言" prop="programmingLanguage" min-width="100" />
                <el-table-column label="源程序量" prop="sourceQuantity" min-width="100" />
                <el-table-column label="主要功能和技术特点" prop="functionAndArt" min-width="100" />

                <el-table-column label="委托日期" prop="principalDates" min-width="100" />
                <el-table-column label="客户期限" prop="customerTerm" min-width="100" />
                <el-table-column label="内部期限" prop="internalWearLife" min-width="100" />
                <el-table-column label="是否配案" prop="isStateCompensation" min-width="100" />
                <el-table-column label="点数用户" prop="click" min-width="100" />
                <el-table-column label="共有人" prop="partOwner" min-width="100" />
                <el-table-column label="办理事项" prop="todonote" min-width="100" />
                <el-table-column label="办理日期" prop="manageDate" min-width="100" />
                <el-table-column label="点数类型" prop="countType" min-width="100" />
                <el-table-column label="点数数量" prop="numberOfPoints" min-width="100" />
                <el-table-column label="点数状态" prop="addtotalstatepoint" min-width="100" />
                <el-table-column label="提成日期" prop="royaltyDate" min-width="100" />
                <el-table-column label="工作量点数" prop="workPoints" min-width="100" />
                <el-table-column label="创建人员" prop="creator" min-width="100" />
                <el-table-column label="费用类型" prop="chargeType" min-width="100" />
                <el-table-column label="币别" prop="currency" min-width="100" />
                <el-table-column label="金额" prop="sum" min-width="100" />
                <el-table-column label="预请款日" prop="advancePaymentDate" min-width="100" />
                <el-table-column label="请款单号" prop="paymentRequestNumber" min-width="100" />
                <el-table-column label="请款日期" prop="requestedDate" min-width="100" />
                <el-table-column label="应收日期" prop="accountsDate" min-width="100" />
                <el-table-column label="发票号" prop="invoiceNumber" min-width="100" />
                <el-table-column label="费用名称" prop="chargeName" min-width="100" />
                <el-table-column label="费用描述" prop="chargeDepict" min-width="100" />
                <el-table-column label="费用描述英文" prop="chargeDepictfine" min-width="100" />
                <el-table-column label="应收金额" prop="extendedAmount" min-width="100" />
                <el-table-column label="折扣率" prop="discountRate" min-width="100" />
                <el-table-column label="数量" prop="count" min-width="100" />
                <el-table-column label="汇率" prop="parities" min-width="100" />
                <el-table-column label="收款公司账户" prop="collectingCompanyAccount" min-width="100" />
                <el-table-column label="收款状态" prop="collectionStatus" min-width="100" />
                <el-table-column label="账户明细" prop="accountDetails" min-width="100" />
                <el-table-column label="开票时间" prop="slt" min-width="100" />
                <el-table-column label="外方账单号" prop="externalBillingNumber" min-width="100" />
                <el-table-column label="外方账单日期" prop="externalBillingDate" min-width="100" />
                <el-table-column label="垫交状态" prop="beddingCondition" min-width="100" />
                <el-table-column label="垫交人" prop="handOver" min-width="100" />
                <el-table-column label="费用备注" prop="expenseNote" min-width="100" />
                <el-table-column label="费减类型" prop="reductionType" min-width="100" />
                <el-table-column label="实际币别" prop="actualCurrency" min-width="100" />
                <el-table-column label="官方期限" prop="officialDeadline" min-width="100" />

                <el-table-column label="相关案名称" prop="relevantCaseName" min-width="100" />
                <el-table-column label="相关类型" prop="correlationType" min-width="100" />

                <el-table-column label="操作人名称" prop="userName" min-width="100" />
                <el-table-column label="创建时间" prop="createTime" min-width="100" />
                <el-table-column label="修改时间" prop="updateTime" min-width="100" />
                <el-table-column label="修改人编号" prop="updateUserId" min-width="100" />
                <el-table-column label="修改人名称" prop="updateUserName" min-width="100" /> -->
                <el-table-column label="操作" width="120" fixed="right">
                    <template #default="{ row }">
                        <el-button
                            v-perms="['case:edit']"
                            type="primary"
                            link
                            @click="handlecopy = true"
                        >
                            复制
                        </el-button>
                        <el-button
                            v-perms="['case:del']"
                            type="danger"
                            link
                            @click="handleDelete(row.id)"
                        >
                            删除
                        </el-button>
                    </template>
                </el-table-column>
            </el-table>
            <div class="flex justify-end mt-4">
                <pagination v-model="pager" @change="getLists" />
            </div>
        </el-card>
        <el-dialog v-model="handlecopy" title="请选择要拷贝的内容">
            <el-form-item label="请选择需要复制的内容" prop="caseType">
                <el-checkbox-group
                    class="w-[740px]"
                    v-model="copytype"
                    placeholder="请选择需要复制的内容"
                >
                    <el-checkbox label="基本信息" value="1" disabled></el-checkbox>
                    <el-checkbox label="承办信息" value="2" disabled></el-checkbox>

                    <el-checkbox label="费用信息" value="5"></el-checkbox>

                    <el-checkbox
                        label="合同信息（往该合同中复制一条新的案件信息）"
                        value="6"
                    ></el-checkbox>
                </el-checkbox-group>
            </el-form-item>
            <template #footer>
                <div class="dialog-footer">
                    <el-button @click="handlecopy = false">取消</el-button>
                    <el-button type="primary" @click="handlecopy = false"> 确定 </el-button>
                </div>
            </template>
        </el-dialog>
        <edit-popup v-if="showEdit" ref="editRef" @success="getLists" @close="showEdit = false" />
    </div>
</template>
<script lang="ts" setup name="case">
import { caseDelete, caseLists } from '@/api/case'
import { usePaging } from '@/hooks/usePaging'
import feedback from '@/utils/feedback'
import EditPopup from './uncoilEdit.vue'
const editRef = shallowRef<InstanceType<typeof EditPopup>>()
const showEdit = ref(false)
const handlecopy = ref(false)
const copytype = ref(['基本信息', '承办信息'])
const queryParams = reactive({
    caseName: '',
    caseType: '',
    businessType: '',
    putinType: '',
    undertakingDepartment: '',
    conductor: '',
    taxRate: '',
    costType: '',
    cost: '',
    contributionPool: '',
    ownershipDistribution: '',
    haveCase: '',
    designatedCountry: '',
    brandType: '',
    classQuantity: '',
    quantity: '',
    officialFee: '',
    agencyFee: '',
    hirdPartyPayment: '',
    signedAmount: '',
    invoiceValue: '',
    fundsReceived: '',
    paidupDateStart: '',
    paidupDateEnd: '',
    planNumber: '',
    caseStatus: '',
    caseLink: '',
    remark: '',
    caseNameid: '',
    businessTypeid: '',
    undertakingDepartmentid: '',
    ownershipDistributionid: '',
    costTypeid: '',
    correlationTypeid: '',
    isRegister: '',
    isInvalid: '',
    isExistingcase: '',
    isPapernotice: '',
    customerDocumentNumber: '',
    copyrightType: '',
    caseFlow: '',
    countryOfOrigin: '',
    agency: '',
    proposalForm: '',
    isMaterials: '',
    isFund: '',
    initialPeriod: '',
    referenceNumber: '',
    contractNumber: '',
    budget: '',
    author: '',
    homeLocation: '',
    softwareAbbreviation: '',
    versionNumber: '',
    softwareWorkDescription: '',
    developmentCompletionDateStart: '',
    developmentCompletionDateEnd: '',
    publishedStatus: '',
    hardwareEnvironment: '',
    softwareEnvironment: '',
    programmingLanguage: '',
    sourceQuantity: '',
    functionAndArt: '',
    handlingInformation: '',
    principalDatesStart: '',
    principalDatesEnd: '',
    customerTermStart: '',
    customerTermEnd: '',
    internalWearLifeStart: '',
    internalWearLifeEnd: '',
    isStateCompensation: '',
    click: '',
    partOwner: '',
    todonote: '',
    manageDateStart: '',
    manageDateEnd: '',
    countType: '',
    numberOfPoints: '',
    addtotalstatepoint: '',
    royaltyDateStart: '',
    royaltyDateEnd: '',
    workPoints: '',
    creator: '',
    chargeType: '',
    currency: '',
    sum: '',
    advancePaymentDateStart: '',
    advancePaymentDateEnd: '',
    paymentRequestNumber: '',
    requestedDateStart: '',
    requestedDateEnd: '',
    accountsDateStart: '',
    accountsDateEnd: '',
    invoiceNumber: '',
    chargeName: '',
    chargeDepict: '',
    chargeDepictfine: '',
    extendedAmount: '',
    discountRate: '',
    count: '',
    parities: '',
    collectingCompanyAccount: '',
    collectionStatus: '',
    accountDetails: '',
    sltStart: '',
    sltEnd: '',
    externalBillingNumber: '',
    externalBillingDateStart: '',
    externalBillingDateEnd: '',
    beddingCondition: '',
    handOver: '',
    expenseNote: '',
    reductionType: '',
    actualCurrency: '',
    officialDeadlineStart: '',
    officialDeadlineEnd: '',
    ourRef: '',
    relevantCaseName: '',
    correlationType: '',
    userId: '',
    userName: '',
    updateUserId: '',
    updateUserName: ''
})

const { pager, getLists, resetPage, resetParams } = usePaging({
    fetchFun: caseLists,
    params: queryParams
})

const handleAdd = async () => {
    showEdit.value = true
    await nextTick()
    editRef.value?.open('add')
}

const handleEdit = async (data: any) => {
    showEdit.value = true
    await nextTick()
    editRef.value?.open('edit')
    editRef.value?.getDetail(data)
}

const handleDelete = async (id: number) => {
    await feedback.confirm('确定要删除？')
    await caseDelete({ id })
    feedback.msgSuccess('删除成功')
    getLists()
}

getLists()
</script>
